#pragma once
#include <vector>

//角色model数据
class Player {
public:
	Player();

	int hp = /*400*/1000;									//生命值
	int money = 0;											//金钱
	int attack = /*10*/1000;								//攻击力
	int defence = /*10*/1000;								//防御力

	int x = 6;										//位置x
	int y = 10;										//位置y

	int yellowKey = 10;								//黄钥匙
	int blueKey = 10;								//蓝钥匙
	int redKey = 10;									//红钥匙

	bool isJDYEnabled = false;						//筋斗云是否可用
	bool isHYJJEnabled = false;						//火眼金睛是否可用

	int currentWeapon = -1;							//当前武器 -1表示无
	int currentArmor = -1;							//当前护甲 -1表示无
	int currentEquipItem = -1;						//当前新装备物品id，用于显示物品描述，显示后会清空

	enum MoveDirection direction;					//朝向
	bool isMoveing = false;							//是否正在移动
	int currentAnimFrame = 0;						//当前动画序列帧

	std::vector<std::pair<int, int>> m_bagItems;	//装备物品，保存id和使用次数，-1表示无限次数
	std::vector<int> m_animSequence;				//动画序列帧

public:
	void setPosition(int x, int y);
	void setDirection(enum MoveDirection direction);
	void anim();
};